package preferencePackage;

import mapPackage.ITronconNonModifiable;
import mapPackage.IVilleNonModifiable;

public class Pref_PasDeRadar extends Preference
{

	public Pref_PasDeRadar(int classement, boolean positif) 
	{
		super(classement, positif);
	}

	public float evaluerDestination(IVilleNonModifiable villeDepart , ITronconNonModifiable troncon)
	{
		float score = 0 ;
		if(positif)
		{
			if( troncon.isRadar() ) score = 1 ;
			else score = 0;
		}
		else
		{
			if( !troncon.isRadar() ) score = 1 ;
			else score = 0;
		}
		
		return score * classement;
	}
}
